package com.jbit.hxy.model.po;


import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

/**
 * 订单表
 * @TableName wx_order
 */
@TableName(value ="wx_order")
@Data
public class WxOrder implements Serializable {
    /**
     * 主键
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 订单号
     */
    @TableField(value = "number")
    private String number;

    /**
     * 订单状态 1待付款 2待接单 3已接单 4派送中 5已完成 6已取消 7退款
     */
    @TableField(value = "status")
    private Integer status;

    /**
     * 下单用户
     */
    @TableField(value = "openid")
    private String openid;

    /**
     * 收货地址ID
     */
    @TableField(value = "addressId")
    private Integer addressId;

    /**
     * 下单时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @TableField(value = "orderTime")
    private LocalDateTime orderTime;

    /**
     * 结账时间
     */
    @TableField(value = "checkoutTime")
    private LocalDateTime checkoutTime;

    /**
     * 支付方式 1微信,2支付宝
     */
    @TableField(value = "payMethod")
    private Integer payMethod;

    /**
     * 支付状态 0-未支付, 1-支付成功, 2-退款中, 3已部分退款, 4-已退款(全额), 5-超时关闭, 6-取消关闭
     */
    @TableField(value = "payStatus")
    private Integer payStatus;

    /**
     * 实收金额
     */
    @TableField(value = "amount")
    private BigDecimal amount;

    /**
     * 订单备注
     */
    @TableField(value = "remark")
    private String remark;

    /**
     * 手机号
     */
    @TableField(value = "phone")
    private String phone;

    /**
     * 地址
     */
    @TableField(value = "address")
    private String address;

    /**
     * 收货人
     */
    @TableField(value = "consignee")
    private String consignee;

    /**
     * 订单取消原因
     */
    @TableField(value = "cancelReason")
    private String cancelReason;

    /**
     * 订单拒绝原因
     */
    @TableField(value = "rejectionReason")
    private String rejectionReason;

    /**
     * 订单取消时间
     */
    @TableField(value = "cancelTime")
    private LocalDateTime cancelTime;

    /**
     * 预计送达时间
     */
    @TableField(value = "estimatedDeliveryTime")
    private LocalDateTime estimatedDeliveryTime;

    /**
     * 配送状态  1立即送出  0选择具体时间
     */
    @TableField(value = "deliveryStatus")
    private Integer deliveryStatus;

    /**
     * 送达时间
     */
    @TableField(value = "deliveryTime")
    private LocalDateTime deliveryTime;

    /**
     * 打包费
     */
    @TableField(value = "packAmount")
    private Integer packAmount;

    /**
     * 餐具数量
     */
    @TableField(value = "tablewareNumber")
    private Integer tablewareNumber;

    /**
     * 餐具数量状态  1按餐量提供  0选择具体数量
     */
    @TableField(value = "tablewareStatus")
    private Integer tablewareStatus;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}